package org.grailsext.annotation;

/**
 *
 * @author Wang Yuxing
 */
@Privileged(privileges = "{test}")
public class PrivilegedTest {

	public static void main(String[] args) {
		PrivilegedTest ins = new PrivilegedTest();
		Class[] classes = ins.getClass().getDeclaredClasses();
		for (Class clazz : classes) {
			if (clazz.getName().equals("")) {
				Privileged annoPriv = (Privileged)clazz.getAnnotation(Privileged.class);
				String[] values = annoPriv.privileges();
				for (String s : values) {
					System.out.println("Value: " + s);
				}
			}
		}

	}

	class InnerClass {
	}
}
